# This is a sample Python script.

# Press Shift+F10 to execute it or replace it with your code.
# Press Double Shift to search everywhere for classes, files, tool windows, actions, and settings.

import torch

print(torch.__version__)
print(torch.__file__)

from pycorrector import Corrector

m = Corrector()
def demo():

    rr = m.correct_batch(['少先队员因该为老人让坐', '你找到你最喜欢的工作，我也很高心。'])
    print(rr)

    tt = '一级域名数：1个，子域名数量：10个，黑白名单个数：20个\n支持HTTP、HTTPS的业务防护（不限于80、8080、443、8443端口），支持针对攻击频繁的恶意IP自动封进，支持防护如SQL注入、命令执行等常见WEB攻击'
    idx_errors = m.detect(tt)
    print(idx_errors)

# Press the green button in the gutter to run the script.
if __name__ == '__main__':
    demo()

# See PyCharm help at https://www.jetbrains.com/help/pycharm/
